# Contributor: Grigory Kirillov <txgk@bk.ru>
# Maintainer: mio <miyopan@e.email>
pkgname=tmatrix
pkgver=1.4
pkgrel=2
pkgdesc="Terminal based replica of the digital rain from The Matrix"
url="https://github.com/M4444/TMatrix"
arch="all"
license="GPL-2.0-only"
makedepends="ncurses-dev cmake samurai"
subpackages="
	$pkgname-doc
	$pkgname-bash-completion
	$pkgname-zsh-completion
	"
source="https://github.com/M4444/TMatrix/archive/v$pkgver/tmatrix-$pkgver.tar.gz"
builddir="$srcdir/TMatrix-$pkgver"

build() {
	cmake -B builddir -G Ninja \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_BUILD_TYPE=Release
	cmake --build builddir
}

check() {
	./builddir/tmatrix --version
}

package() {
	DESTDIR="$pkgdir" cmake --install builddir
}

sha512sums="
eacb6359db33282c372514397feb399a110df5c590870035babcdaa7f7c5ec30e2b05b5f2b6212232d7322ffbdda0d52aa46f8e4038473f5e62ac482f1652187  tmatrix-1.4.tar.gz
"
